Exercise 9: Table reference

In this exercise we specify an attachment in the Loans module to several Catalogue records (the objects loaned).

As we've seen, a Typical import is configured to deal with attachments as follows. Using the search values specified in your Import data file:

  • A search is performed on all existing records in the specified module.
  • If no match is found, a new record is added and an attachment is made to it.
  • If a single matching record is found, an attachment is made to that record.
  • If more than one match is found, the matching records are displayed so that the correct record can be selected manually.
  1. Create a new CSV Import data file with the following details:

Column Name

(Row 1)

Record 1

(Row 2)

Record 2

(Row 3)

InfDirection

Outgoing

Incoming

InfLoanStatusValue

Ongoing

Ongoing

InfReasonForLoan

Exhibition

Research

DatLoanCommencementDate

[Today]

[Today]

DatLoanDueDate

[Same day next year]

[Same day next month]

ObjObjectsLoanedRef_tab(1).TitAccessionNo

1957.161

 

ObjObjectNotes_tab(1)

On loan to the National Museum

Research undertaken by [Your login name]

ObjObjectsLoanedRef_tab(1).ObjectType

 

Object

ObjObjectsLoanedRef_tab(1).TitObjectStatus

 

Inward Loan

ObjObjectsLoanedRef_tab(1).TitMainTitle

 

[Your login name]

ObjObjectsLoanedRef_tab(1).TitObjectCategory

 

Work of Art

ObjObjectsLoanedRef_tab(2).TitAccessionNo

1995.39.38

 

ObjObjectNotes_tab(2)

On loan to the National Museum

 

ObjObjectsLoanedRef_tab(3).TitAccessionNo

1978.138

 

ObjObjectNotes_tab(3)

On loan to the National Museum

 

The Import data file specifies that Record 1 is an Outgoing loan for three objects in the Catalogue. In the Object: (Objects Loaned) table in the Loans module, a note is added for each object loaned.

Record 2 is an Incoming loan which will create a Catalogue record for the incoming loan object.

  1. Save the Import data file as exercise9_train1.csv (where Train1 is your login name).
  2. Before importing the data, perform a Custom Import to validate the Import data file.
  3. When there are no validation errors, perform a Typical Import (and remember to include your login name as the Import Identifier).

    The Importing screen should appear as:

    db_importing_table_attachments_train.gif

    • Two records have been created in the Loans module, for an Outgoing and an Incoming loan.
    • One record was created in the Catalogue module for the Incoming Loan.
    • Three attachments (to the existing object records) were made to the Catalogue module for the Outgoing Loan (i.e. these are the objects we are lending and they are, naturally, already recorded in the Catalogue module).
  4. Record the IRN of the Catalogue record created. You'll need this for Exercise 10:

    __________

  5. How many attachments would be made if you ran this same import again?:

    __________

  6. Run the import again to see if you answered question 6 correctly.
  7. Why are there this number of attachments?

    Confirm with your instructor that you've understood why.